import json

import requests
from urllib import parse
import re
import redis

url = "http://news.51cto.com/"
proxies = {'http': 'http://144.217.118.206:8080'}

# 空白位置为测试代理ip和代理ip使用端口

headers = {
    'User-Agent': "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/78.0.3904.97 Safari/537.36",
}
# 响应头
res = requests.get(url, proxies=proxies, headers=headers)
# 发起请求
print(res.status_code)  # 返回响应码
print(res.text)

# str = parse.unquote(
#     'nextContent([[{"msg":0,"ID":"611938","title":"\u8fd98\u4e2a\u9526\u56ca\uff0c\u52a9\u4f60\u6210\u4e3a\u4e00\u540d\u4f18\u79c0\u7684Java\u5f00\u53d1\u8005","picname":"https:\/\/s5.51cto.com\/oss\/202003\/05\/8d40b8f6808568daccc90399df74798e.jpg","url":"http:\/\/developer.51cto.com\/art\/202003\/611938.htm","stime":"2020-03-05 13:40:49","typeid":"2","thumb":"https:\/\/s5.51cto.com\/oss\/202003\/05\/8d40b8f6808568daccc90399df74798e.jpg","has_thumb":true,"info":"\u79c1\u5e95\u4e0b\uff0c\u9694\u4e09\u5dee\u4e94\u5c31\u6709\u8bfb\u8005\u95ee\u6211\uff1a\u201c\u4e8c\u54e5\uff0c\u600e\u4e48\u6837\u624d\u80fd\u50cf\u4f60\u4e00\u6837\uff0c\u6210\u4e3a\u4e00\u540d\u4f18\u79c0\u7684 Java \u5f00\u53d1\u8005\u5462\uff1f\u201d\u5047\u5982\u628a\u201c\u600e","keywords":"\u5de5\u5177<\/a>\u5f00\u53d1<\/a>Java<\/a>","typename":"\u70ed\u70b9\u89c2\u5bdf","typedomain":"http:\/\/news.51cto.com\/col\/2"},{"msg":0,"ID":"611932","title":"2020\u5e74 JVM \u751f\u6001\u62a5\u544a\u89e3\u8bfb","picname":"https:\/\/s4.51cto.com\/oss\/202003\/05\/073679be3d958f5b9e6764f603a4c449.jpeg","url":"http:\/\/news.51cto.com\/art\/202003\/611932.htm","stime":"2020-03-05 12:10:56","typeid":"2","thumb":"https:\/\/s4.51cto.com\/oss\/202003\/05\/073679be3d958f5b9e6764f603a4c449.jpeg","has_thumb":true,"info":"\u6211\u4eec\u6765\u770b\u770b JVM \u751f\u6001\u5708\u6700\u65b0\u7684\u60c5\u51b5\u4ee5\u53ca\u53d1\u5c55\u7684\u8d8b\u52bf\uff0c\u8fd9\u5bf9 Java \u5f00\u53d1\u8005\u81f3\u5173\u91cd\u8981\u3002","keywords":"\u4ee3\u7801<\/a>\u5f00\u53d1<\/a>Java<\/a>","typename":"\u70ed\u70b9\u89c2\u5bdf","typedomain":"http:\/\/news.51cto.com\/col\/2"},{"msg":0,"ID":"611929","title":"\u522b\u7528\u6536\u8d39\u7684Postman\u4e86\uff0c\u8003\u8651\u4e00\u4e0b\u514d\u8d39\u5f00\u6e90\u7684Postwoman","picname":"https:\/\/s2.51cto.com\/oss\/202003\/05\/7bd76231e6f6c5e48dd690176099b069.jpeg","url":"http:\/\/news.51cto.com\/art\/202003\/611929.htm","stime":"2020-03-05 11:40:46","typeid":"2","thumb":"https:\/\/s2.51cto.com\/oss\/202003\/05\/7bd76231e6f6c5e48dd690176099b069.jpeg","has_thumb":true,"info":" API\u63a5\u53e3\u8c03\u8bd5\u5728\u5f00\u53d1\u8fc7\u7a0b\u4e2d\u662f\u975e\u5e38\u91cd\u8981\u7684\u4e00\u4e2a\u73af\u8282\uff0c\u5927\u5bb6\u90fd\u77e5\u9053\uff0cPostman\u662f\u4e00\u4e2a\u975e\u5e38\u53d7\u6b22\u8fce\u7684API\u63a5\u53e3\u8c03\u8bd5\u5de5\u5177\uff0c","keywords":"\u8d8b\u52bf<\/a>\u6280\u672f <\/a>\u5f00\u6e90<\/a>","typename":"\u70ed\u70b9\u89c2\u5bdf","typedomain":"http:\/\/news.51cto.com\/col\/2"},{"msg":0,"ID":"611931","title":"\u5237\u8138\u652f\u4ed8\u8fd8\u4e0d\u591f\uff0c\u4e07\u4e8b\u8fbe\u5361\u63a2\u7d22\u6b65\u6001\u3001\u5fc3\u8df3\u548c\u9759\u8109\u65b9\u5f0f\u652f\u4ed8","picname":"https:\/\/s1.51cto.com\/oss\/202003\/05\/8309ec61fd809072301920cf317415c5.jpeg","url":"http:\/\/news.51cto.com\/art\/202003\/611931.htm","stime":"2020-03-05 11:10:20","typeid":"2","thumb":"https:\/\/s1.51cto.com\/oss\/202003\/05\/8309ec61fd809072301920cf317415c5.jpeg","has_thumb":true,"info":"\u8fd1\u65e5\uff0c\u5168\u7403\u652f\u4ed8\u89e3\u51b3\u65b9\u6848\u5de8\u5934\u4e07\u4e8b\u8fbe\u5361\u5728\u63a5\u53d7\u5a92\u4f53\u91c7\u8bbf\u65f6\u900f\u9732\uff0c\u6bcf\u4e2a\u4eba\u90fd\u6709\u81ea\u5df1\u72ec\u7279\u7684\u8d70\u8def\u65b9\u5f0f\uff0c\u5e76\u4e14\u516c\u53f8\u76ee\u524d\u6b63","keywords":"\u4eba\u5de5\u667a\u80fd<\/a>\u6570\u636e<\/a>AI <\/a>","typename":"\u70ed\u70b9\u89c2\u5bdf","typedomain":"http:\/\/news.51cto.com\/col\/2"},{"msg":0,"ID":"611926","title":"\u90a3\u4e9b\u5f71\u54cd\u4e86\u51e0\u4ee3\u7a0b\u5e8f\u5458\u7684\u7f16\u7a0b\u4e66\u7c4d","picname":"https:\/\/s5.51cto.com\/oss\/202003\/05\/34acd7b66764cebf977b9e02da40a08f.png","url":"http:\/\/developer.51cto.com\/art\/202003\/611926.htm","stime":"2020-03-05 11:02:38","typeid":"576","thumb":"https:\/\/s5.51cto.com\/oss\/202003\/05\/34acd7b66764cebf977b9e02da40a08f.png","has_thumb":true,"info":"\u8fd9\u4e9b\u4e66\u5e76\u4e0d\u4f1a\u7acb\u9a6c\u4f7f\u4f60\u6210\u4e3a\u4e00\u540d\u51fa\u8272\u7684\u7a0b\u5e8f\u5458\uff0c\u4f46\u5b83\u4eec\u786e\u5b9e\u662f\u5f71\u54cd\u4e86\u65e0\u6570\u7a0b\u5e8f\u5458\u7684\u4e66\u7c4d\uff0c\u9605\u8bfb\u8fd9\u4e9b\u4e66\u7c4d\u53ef\u4ee5\u5e2e\u52a9\u5f00","keywords":"\u4e66\u7c4d<\/a>\u7f16\u7a0b<\/a>\u7a0b\u5e8f\u5458<\/a>","typename":"\u5feb\u8baf","typedomain":"http:\/\/developer.51cto.com\/col\/576"},{"msg":0,"ID":"611916","title":"\u5982\u4f55\u5728 2020 \u5e74\u7528 Java \u5b89\u5168\u7f16\u7a0b","picname":"https:\/\/s3.51cto.com\/oss\/202003\/05\/c631a54e710f6497b586041d398849fc.jpg","url":"http:\/\/developer.51cto.com\/art\/202003\/611916.htm","stime":"2020-03-05 10:10:51","typeid":"2","thumb":"https:\/\/s3.51cto.com\/oss\/202003\/05\/c631a54e710f6497b586041d398849fc.jpg","has_thumb":true,"info":"\u4e00\u4f4d\u540d\u4e3a Sam Bocetta \u7684\u4f5c\u8005\u53d1\u8868\u4e86\u4e00\u7bc7\u6587\u7ae0\uff0c\u9488\u5bf9\u5728 2020 \u5e74\u4f7f\u7528 Java \u8fdb\u884c\u7f16\u7801\u65f6\u5e94\u9075\u5faa\u7684\u4e94\u4e2a\u539f\u5219\u8fdb\u884c\u4e86","keywords":"\u5f00\u53d1<\/a>\u5b89\u5168<\/a>Java<\/a>","typename":"\u70ed\u70b9\u89c2\u5bdf","typedomain":"http:\/\/news.51cto.com\/col\/2"},{"msg":0,"ID":"611912","title":"\u529e\u516c\u5c0f\u6280\u5de7\uff1aExcel\u52a8\u6001\u56fe\u8868\u5373\u70b9\u5373\u53d8","picname":"https:\/\/s3.51cto.com\/oss\/202003\/05\/3073ed4eda919e9c728505f6bd416791.jpg","url":"http:\/\/news.51cto.com\/art\/202003\/611912.htm","stime":"2020-03-05 09:59:45","typeid":"2","thumb":"https:\/\/s3.51cto.com\/oss\/202003\/05\/3073ed4eda919e9c728505f6bd416791.jpg","has_thumb":true,"info":"Excel\u4e2d\u7684\u5e38\u89c4\u56fe\u8868\u5f80\u5f80\u662f\u9759\u6001\u7684\uff0c\u4e00\u822c\u662f\u5728\u9009\u62e9\u76f8\u5e94\u7684\u6570\u636e\u540e\u81ea\u52a8\u751f\u6210\uff0c\u6f14\u793a\u65f6\u56fa\u5b9a\u4e0d\u53d8\u3002\u4e0d\u8fc7\u9047\u5230\u53d8\u5316\u8f83\u591a\u7684","keywords":"\u6570\u636e<\/a>\u529e\u516c<\/a>Excel<\/a>","typename":"\u70ed\u70b9\u89c2\u5bdf","typedomain":"http:\/\/news.51cto.com\/col\/2"},{"msg":0,"ID":"611917","title":"TIOBE 3 \u6708\u699c\u5355\uff1aDelphi \u7ec8\u5c06\u6ca1\u843d\uff1f","picname":"https:\/\/s4.51cto.com\/oss\/202003\/05\/777b86dd8831bfafa223de01458afa97.jpg","url":"http:\/\/news.51cto.com\/art\/202003\/611917.htm","stime":"2020-03-05 09:50:16","typeid":"2","thumb":"https:\/\/s4.51cto.com\/oss\/202003\/05\/777b86dd8831bfafa223de01458afa97.jpg","has_thumb":true,"info":"C \u8bed\u8a00\u4e0d\u6127\u662f\u5e74\u5ea6\u7f16\u7a0b\u8bed\u8a00\uff0c\u4ee5 3.03% \u7684\u5e74\u589e\u957f\u7387\u7ee7\u7eed\u5927\u5e45\u9886\u5148\u3002\u5e74\u589e\u957f\u7387\u8f83\u9ad8\u7684\u8fd8\u6709 Java\uff082.90%\uff09\u3001C#\uff082.9","keywords":"Java<\/a>Python<\/a>\u7f16\u7a0b\u8bed\u8a00<\/a>","typename":"\u70ed\u70b9\u89c2\u5bdf","typedomain":"http:\/\/news.51cto.com\/col\/2"},{"msg":0,"ID":"611898","title":"\u9ebb\u7701\u7406\u5de5\u5b66\u9662\u63d0\u540d2020\u5e74\u5341\u5927\u7a81\u7834\u6027\u6280\u672f","picname":"https:\/\/s3.51cto.com\/oss\/202003\/05\/481bec4efc7e9db9b18079bc27340541.jpeg","url":"http:\/\/news.51cto.com\/art\/202003\/611898.htm","stime":"2020-03-05 08:19:03","typeid":"2","thumb":"https:\/\/s3.51cto.com\/oss\/202003\/05\/481bec4efc7e9db9b18079bc27340541.jpeg","has_thumb":true,"info":"\u53c8\u662f\u65b0\u7684\u4e00\u5e74\uff0c\u5fb7\u9ad8\u671b\u91cd\u7684\u300aMIT\u6280\u672f\u8bc4\u8bba\u300b\u518d\u6b21\u516c\u5e03\u63a5\u4e0b\u6765\u6700\u503c\u5f97\u5173\u6ce8\u3001\u800c\u4e14\u6709\u671b\u57282020\u5e74\u7ed9\u4eba\u7c7b\u793e\u4f1a\u5e26\u6765\u5e7f\u6cdb","keywords":"\u6570\u5b57\u6280\u672f<\/a>AI<\/a>\u6280\u672f<\/a>","typename":"\u70ed\u70b9\u89c2\u5bdf","typedomain":"http:\/\/news.51cto.com\/col\/2"},{"msg":0,"ID":"611886","title":"180\u6240\u9ad8\u6821\u83b7\u6279\u65b0\u589e\u4eba\u5de5\u667a\u80fd\u4e13\u4e1a\uff0c\u4f60\u5efa\u8bae\u62a5\u8003\u5417\uff1f","picname":"https:\/\/s3.51cto.com\/oss\/202003\/04\/22243b437e23a903055f2ab4fbdaf460.jpg","url":"http:\/\/news.51cto.com\/art\/202003\/611886.htm","stime":"2020-03-04 17:29:59","typeid":"2","thumb":"https:\/\/s3.51cto.com\/oss\/202003\/04\/22243b437e23a903055f2ab4fbdaf460.jpg","has_thumb":true,"info":"\u5728\u6559\u80b2\u90e8\u6700\u65b0\u516c\u5e03\u7684\u65b0\u589e\u5907\u6848\u672c\u79d1\u4e13\u4e1a\u540d\u5355\u4e2d\uff0c\u7ea6 180 \u6240\u9ad8\u6821\u901a\u8fc7\u4e86\u65b0\u589e\u4eba\u5de5\u667a\u80fd\u4e13\u4e1a\u7684\u5ba1\u6279\uff0c\u5176\u4e2d\u65e2\u5305\u62ec\u7406\u5de5","keywords":"\u5927\u5b66<\/a>\u6570\u5b66<\/a>\u4eba\u5de5\u667a\u80fd<\/a>","typename":"\u70ed\u70b9\u89c2\u5bdf","typedomain":"http:\/\/news.51cto.com\/col\/2"},{"msg":0,"ID":"611887","title":"\u75ab\u60c5\u4e4b\u4e0b\u65e0\u4eba\u96f6\u552e\u6210\u7206\u6b3e \u662f\u6d74\u706b\u91cd\u751f\u8fd8\u662f\u56de\u5149\u8fd4\u7167\uff1f","picname":"https:\/\/s1.51cto.com\/oss\/202003\/04\/4c59b58099f1ee5e13428d13becc569c.jpg","url":"http:\/\/news.51cto.com\/art\/202003\/611887.htm","stime":"2020-03-04 17:26:02","typeid":"2","thumb":"https:\/\/s1.51cto.com\/oss\/202003\/04\/4c59b58099f1ee5e13428d13becc569c.jpg","has_thumb":true,"info":"\u7e41\u534e\u843d\u5e55\u540e\uff0c\u65f6\u9694\u516d\u767e\u4e2a\u65e5\u591c\uff0c\u56e0\u4e3a\u65b0\u578b\u51a0\u72b6\u75c5\u6bd2\u80ba\u708e\u7684\u75ab\u60c5\u8086\u8650\uff0c\u66fe\u7ecf\u6de1\u51fa\u4eba\u4eec\u89c6\u7ebf\u7684\u65e0\u4eba\u96f6\u552e\uff0c\u5374\u4f3c\u4e4e\u5927\u6709\u53d6","keywords":"\u65e0\u4eba\u96f6\u552e<\/a>\u96f6\u552e<\/a>\u75ab\u60c5<\/a>","typename":"\u70ed\u70b9\u89c2\u5bdf","typedomain":"http:\/\/news.51cto.com\/col\/2"},{"msg":0,"ID":"611883","title":"\u6027\u4ef7\u6bd4\u4e4b\u738b\uff01\u5f20\u79d1\u51fa\u4efb\u8f7b\u677e\u96c6\u56e2CEO\u6253\u9020\u7684\u9996\u6b3e\u957f\u671f\u91cd\u75be\u9669\u4ea7\u54c1\uff0c\u76f4\u64ad\u7834200\u4e07\u89c2\u770b","picname":"https:\/\/s3.51cto.com\/oss\/202003\/04\/e491fd534e105ba60362674f3105a027.jpg","url":"http:\/\/news.51cto.com\/art\/202003\/611883.htm","stime":"2020-03-04 17:13:31","typeid":"2","thumb":"https:\/\/s3.51cto.com\/oss\/202003\/04\/e491fd534e105ba60362674f3105a027.jpg","has_thumb":true,"info":"\u201c\u4fdd\u9669\u7684\u6838\u5fc3\u662f\u4fdd\u969c\uff0c\u4fdd\u969c\u7684\u5bf9\u8c61\u662f\u6709\u7279\u5b9a\u9700\u6c42\u7684\u7528\u6237\u201d\u5f20\u79d1\u81ea\u51fa\u4efb\u8f7b\u677e\u96c6\u56e2CEO\u4ee5\u6765\uff0c\u591a\u6b21\u5f3a\u8c03\u201c\u53ea\u4e3a\u7528\u6237\u800c\u751f","keywords":"\u8f7b\u677e\u7b79<\/a>","typename":"\u70ed\u70b9\u89c2\u5bdf","typedomain":"http:\/\/news.51cto.com\/col\/2"},{"msg":0,"ID":"611880","title":"\u89e3\u8bfb\uff1a\u5e7f\u7535\u201c\u4e00\u7f51\u6574\u5408\u201d\u4e0e5G\u5927\u4e1a","picname":"https:\/\/s3.51cto.com\/oss\/202003\/04\/7f5046fa680dc89599a667ecc85d865f.jpg","url":"http:\/\/network.51cto.com\/art\/202003\/611880.htm","stime":"2020-03-04 16:55:00","typeid":"552","thumb":"https:\/\/s3.51cto.com\/oss\/202003\/04\/7f5046fa680dc89599a667ecc85d865f.jpg","has_thumb":true,"info":"3\u67082\u65e5\u4e0b\u5348\uff0c\u56fd\u5bb6\u5e7f\u64ad\u7535\u89c6\u603b\u5c40\u53ec\u5f00\u4e86\u201c\u8d2f\u5f7b\u843d\u5b9e\u300a\u5168\u56fd\u6709\u7ebf\u7535\u89c6\u7f51\u7edc\u6574\u5408\u53d1\u5c55\u5b9e\u65bd\u65b9\u6848\u300b\u7535\u89c6\u7535\u8bdd\u4f1a\u8bae\u201d\uff0c\u5e76\u4e14","keywords":"\u6574\u5408<\/a>5G<\/a>\u5e7f\u7535<\/a>","typename":"\u65b0\u95fb\u52a8\u6001","typedomain":"http:\/\/network.51cto.com\/col\/552"},{"msg":0,"ID":"611874","title":"\u6bd5\u4e1a6\u5e74\uff0c\u6280\u672f\u4eba\u7684\u4e0d\u60d1\u4e4b\u8def","picname":"https:\/\/s2.51cto.com\/oss\/202003\/04\/57e1b7eadb138bceb03ad07bce0465a0.png","url":"http:\/\/news.51cto.com\/art\/202003\/611874.htm","stime":"2020-03-04 16:18:32","typeid":"2","thumb":"https:\/\/s2.51cto.com\/oss\/202003\/04\/57e1b7eadb138bceb03ad07bce0465a0.png","has_thumb":true,"info":"\u672c\u4eba\u4e8c\u672c(\u56fd\u5185\u6392\u540d500\u540d\u5f00\u5916)\u6bd5\u4e1a6\u5e74\uff0c\u4ece\u6bd5\u4e1a\u5230\u73b0\u5728\u6362\u8fc7\u4e09\u6b21\u5de5\u4f5c(\u4f4e\u4e8e\u4e00\u4e2a\u6708\u7684\u4e0d\u7b97)\uff0c\u671f\u95f4\u5f85\u8fc7\u5c0f\u516c\u53f8\u3001B\u8f6e","keywords":"\u5de5\u4f5c<\/a>\u4e92\u8054\u7f51<\/a>\u516c\u53f8<\/a>","typename":"\u70ed\u70b9\u89c2\u5bdf","typedomain":"http:\/\/news.51cto.com\/col\/2"},{"msg":0,"ID":"611871","title":"Java\u7a0b\u5e8f\u5458\u73b0\u8eab\u8bf4\u6cd5\uff1a37\u5c81\u8001\u7801\u519c\u627e\u5de5\u4f5c\u7684\u7ecf\u5386\uff0c\u7a9d\u56ca\u7684\u54ed\u4e86..","picname":"https:\/\/s4.51cto.com\/oss\/202003\/04\/4c19409a03614da95324db9ee72d874f.jpg","url":"http:\/\/news.51cto.com\/art\/202003\/611871.htm","stime":"2020-03-04 15:56:16","typeid":"2","thumb":"https:\/\/s4.51cto.com\/oss\/202003\/04\/4c19409a03614da95324db9ee72d874f.jpg","has_thumb":true,"info":"\u524d\u51e0\u5929\u7a81\u7136\u63a5\u5230dk\u7684\u7535\u8bdd\uff0c\u8981\u548c\u6211\u804a\u804a\u5929\u3002\u4ed6\u8bf4\u4ed6\u4eec\u90e8\u95e8\u8c03\u6574\uff0c\u867d\u7136\u6700\u540e\u4ed6\u7559\u4e86\u4e0b\u6765\uff0c\u4f46\u8fd8\u662f\u975e\u5e38\u7126\u8651\u3002\u4eba\u65e0\u8fdc\u8651","keywords":"\u5f00\u53d1<\/a>\u7a0b\u5e8f\u5458<\/a>\u7801\u519c<\/a>","typename":"\u70ed\u70b9\u89c2\u5bdf","typedomain":"http:\/\/news.51cto.com\/col\/2"},{"msg":0,"ID":"611864","title":"\u6ce2\u58eb\u987f\u52a8\u529b\u53cc\u8f6e\u673a\u5668\u4ebaHandle\u5373\u5c06\u51fa\u9053\uff01\u4e0e\u7269\u6d41\u673a\u5668\u4ebaOTTO\u642d\u6863\u8fd0\u8d27","picname":"https:\/\/s4.51cto.com\/oss\/202003\/04\/b9ddc55137135b7f27e2530d47414f2d.jpg","url":"http:\/\/news.51cto.com\/art\/202003\/611864.htm","stime":"2020-03-04 15:10:16","typeid":"2","thumb":"https:\/\/s4.51cto.com\/oss\/202003\/04\/b9ddc55137135b7f27e2530d47414f2d.jpg","has_thumb":true,"info":"\u73b0\u5728\uff0c\u6ce2\u58eb\u987f\u52a8\u529b\u5ba3\u5e03\uff0c\u5df2\u7ecf\u548c\u81ea\u52a8\u9a7e\u9a76\u516c\u53f8OTTO Motors\u8fbe\u6210\u4e86\u5408\u4f5c\uff0c\u53cc\u65b9\u7684\u673a\u5668\u4eba\u5728\u4ed3\u5e93\u573a\u666f\u7ec4\u961f\u5de5\u4f5c\uff0c\u5171\u540c","keywords":"\u7cfb\u7edf<\/a>\u4eba\u5de5\u667a\u80fd<\/a>\u673a\u5668\u4eba<\/a>","typename":"\u70ed\u70b9\u89c2\u5bdf","typedomain":"http:\/\/news.51cto.com\/col\/2"},{"msg":0,"ID":"611861","title":"\u901a\u8fc7\u533a\u5757\u94fe\u6280\u672f\u5b9e\u73b0\u65b0\u7684\u4e1a\u52a1\u5f00\u5c55\u65b9\u5f0f","picname":"https:\/\/s2.51cto.com\/oss\/202003\/04\/d36a80a9f5b8fce3b41210d6993c07b0.jpg","url":"http:\/\/blockchain.51cto.com\/art\/202003\/611861.htm","stime":"2020-03-04 14:31:04","typeid":"384","thumb":"https:\/\/s2.51cto.com\/oss\/202003\/04\/d36a80a9f5b8fce3b41210d6993c07b0.jpg","has_thumb":true,"info":"\u672c\u6587\u5c06\u4ecb\u7ecd\u4e09\u4e2a\u6784\u5efa\u5728AWS\u4e0a\u7684\u533a\u5757\u94fe\u6280\u672f\u5e94\u7528\u573a\u666f\uff0c\u4f7f\u7528AWS\u89e3\u51b3\u4e86\u5ba2\u6237\u75db\u70b9\uff0c\u4e3a\u591a\u4e2a\u884c\u4e1a\u5f00\u5c55\u4e1a\u52a1\u63d0\u4f9b\u4e86\u65b0\u7684\u65b9","keywords":"\u533a\u5757\u94fe<\/a>AWS<\/a>","typename":"\u4e91\u8d44\u8baf","typedomain":"http:\/\/cloud.51cto.com\/col\/384"},{"msg":0,"ID":"611860","title":"\u786c\u6838\u7f16\u7a0b\u6280\u672f\u52a9\u529b\u75ab\u60c5\u9632\u63a7\uff0c\u7f16\u7a0b\u6559\u80b2\u7684\u4e0b\u4e00\u4e2a\u8d8b\u52bf\u662f\u4ec0\u4e48\uff1f","picname":"https:\/\/s2.51cto.com\/oss\/202003\/04\/9629925834322fefd1a14e6ed28edb3c.jpg","url":"http:\/\/news.51cto.com\/art\/202003\/611860.htm","stime":"2020-03-04 14:28:40","typeid":"2","thumb":"https:\/\/s2.51cto.com\/oss\/202003\/04\/9629925834322fefd1a14e6ed28edb3c.jpg","has_thumb":true,"info":"\u300a\u65b0\u4e00\u4ee3\u4eba\u5de5\u667a\u80fd\u53d1\u5c55\u89c4\u5212\u300b\u4e2d\u6709\u4e00\u53e5\u8bdd\u5f88\u91cd\u8981\uff1a\u9f13\u52b1\u793e\u4f1a\u529b\u91cf\u53c2\u4e0e\u5bd3\u6559\u4e8e\u4e50\u7684\u7f16\u7a0b\u6559\u5b66\u8f6f\u4ef6\u3001\u6e38\u620f\u7684\u5f00\u53d1\u548c\u63a8\u5e7f","keywords":"Java<\/a>Python<\/a>\u7f16\u7a0b\u8bed\u8a00<\/a>","typename":"\u70ed\u70b9\u89c2\u5bdf","typedomain":"http:\/\/news.51cto.com\/col\/2"},{"msg":0,"ID":"611859","title":"10\u4e07\u73a9\u5bb6\u597d\u8bc4\uff01\u300a\u6211\u7684\u516c\u53f8996\u300b\u201c\u795e\u8fd8\u539f\u201d\u4e2d\u56fd\u804c\u573a","picname":"https:\/\/s4.51cto.com\/oss\/202003\/04\/3f58d0cb91b55c40b4ab89f4f6b1e0a1.jpg","url":"http:\/\/news.51cto.com\/art\/202003\/611859.htm","stime":"2020-03-04 13:55:44","typeid":"2","thumb":"https:\/\/s4.51cto.com\/oss\/202003\/04\/3f58d0cb91b55c40b4ab89f4f6b1e0a1.jpg","has_thumb":true,"info":"\u8fd1\u65e5\uff0c\u5728 TapTap \u4e0a\u4fbf\u6709\u4e00\u6b3e\u4ee5\u4e92\u8054\u7f51\u4e3a\u516c\u53f8\u7ecf\u5386\u4e3a\u9898\u6750\u7684\u6e38\u620f\u300a\u6211\u7684\u516c\u53f8 996\u300b\uff0c\u5728\u5f00\u542f\u4e86\u6d4b\u8bd5\u540e\u8fc5\u901f\u83b7\u5f97\u4e86\u4e0d","keywords":"\u5f00\u53d1\u8005<\/a>\u6280\u80fd<\/a>\u7a0b\u5e8f\u5458<\/a>","typename":"\u70ed\u70b9\u89c2\u5bdf","typedomain":"http:\/\/news.51cto.com\/col\/2"}],1])')
#
# regex = "[/]*"
# str = re.sub(regex, "", str)
# print(str)
import simplejson as simplejson

# headers = {
#     "User-Agent": "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/78.0.3904.97 Safari/537.36"}
# data = {
#     "page": 53,
#     "type_id": 558,
#     "type": "recommend",
#     "callback":"nextContent"
# }
# s = requests.get(url='https://www.51cto.com/php/get_channel_recommend_art_list.php?', params=data, headers=headers)
#
# str1 = s.text.encode("utf-8").decode("unicode-escape")
#
# regex = r"\\"
# str = re.sub(regex, "", str1)
# str2=str[12:-1]
# print("提取："+ str2)
# jsonObj = json.loads(str2)
#
# print([jsonObj[0][i]["url"] for i in range(len(jsonObj[0]))])
# print(jsonObj[1] == 0)

# redis_cli = redis.StrictRedis(decode_responses=True)
# print(redis_cli.get("page"))
# # redis_cli.set("page", 2)
# redis_cli.set("51cto_count",4727)
# print(redis_cli.get("page"))
